<?php  session_start();
/**
* @package		Parents@School
* @copyright	                Copyright (C) 2008 Kristof Beckers. All rights reserved.
* @Version		2.0
* @license		GNU/GPL, see LICENSE.php
**/
include ("../include/config.php");
require_once ("../include/db.php");
include ("../include/header.php");
?>
<head>
<link rel="stylesheet" href="../css/template_css.css" type="text/css"/> 
</head>

<body>
<div align="center"><img src="<?php echo "$logo" ; ?>" /><br><br>
<a href="../index.php"/><img src="<?php echo "$home" ; ?>" border="0"/></a><br><br>

<?php
if(isset($_SESSION['myusername'])){
$id = $_GET['id'];
?>
Volgende afspraak is met success verwijderd
	<table class='moduletable-latest1'>
		<tr>
		<td width='25%'>Leerkracht</td>
		<td width='25%'>Uur</td>
		<td width='25%'>Vak</td>
		<td width='25%'>Lokaal</td>
		</tr>
</table>
<?php
$sql = "SELECT * FROM $tbres WHERE ReservatieID='$id'";
$result = mysql_query($sql);


while ($row = mysql_fetch_array($result)){
		$lkid = $row['LeerkrachtID'];
		$uur = $row['Uur'];
		$resid = $row['ReservatieID'];
		$lknaam = $row['Leerkrachtnaam'];
		$klas = $row['Klas'];
		$lokaal = $row['Lokaal'];
		$vak = $row['Vak'];
		echo " <table class='moduletable-latest1'>
		<tr>
		<td width='25%'>$lknaam</td>
		<td width='25%'>$uur</td>
		<td width='25%'>$vak</td>
		<td width='25%'>$lokaal</td>
		</tr>
		</table>";}
		
$sql2 = "DELETE FROM $tbres WHERE ReservatieID='$id' ";

$delete = mysql_query($sql2);


}
else{
echo "Gelieve eerst in te loggen.";
}
mysql_close()
?>
</div>
</body>